<template>
  <!-- 搜索 -->
  <el-form :inline="true" label-width="70px">
    <el-form-item label="作者" style="width: 230px">
      <el-input v-model="search.author" placeholder="请输入作者名称" />
    </el-form-item>
    <!-- <el-form-item label="书名" style="width: 230px">
        <el-input v-model="search.bookname" placeholder="请输入书名" />
      </el-form-item> -->
    <!-- <el-form-item label="显示" style="width: 230px">
        <el-select placeholder="请选择" v-model="search.status">
          <el-option label="显示" value="1" />
          <el-option label="隐藏" value="0" />
        </el-select>
      </el-form-item> -->
    <el-form-item>
      <el-button type="primary" @click="onSubmit">查询</el-button>
    </el-form-item>
  </el-form>
  <!-- /搜索 -->
</template>
  
<script>
export default {
  data() {
    return {
      search: {
        author: "",
      },
    };
  },
  methods: {
    onSubmit() {
      this.$emit("onSearch", {
        author: this.search.author,
        page: 1,
        pageSize: 10,
      });
    },
    reset() {
      this.search = {
        author: "",
      }
    }
  },
};
</script>
  
<style lang="scss" scoped></style>